package com.xm.spi;

import com.xm.Car;

import java.util.ServiceLoader;

/**
 * Author：xm
 * Project：demo
 * Date：2025/8/27  17:42
 */

public class Application {
    public static void main(String[] args) {
        ServiceLoader<Car> carServiceLoader = ServiceLoader.load(Car.class);
        carServiceLoader.forEach(service -> service.driver());
    }
}
